package teach.aistar.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import teach.aistar.mapper.ChatMapper;

import teach.aistar.model.entity.Chat;
import teach.aistar.service.IChatService;

import java.util.List;

@Service
@Transactional
public class ChatServiceImpl implements IChatService {

    @Autowired
    private ChatMapper chatMapper;

    @Override
    public List<Chat> selectByType(int textType) {
        return chatMapper.selectByType(textType);
    }

    @Override
    public int insert(Chat chat) {
        return chatMapper.insert(chat);
    }
}
